/* 
 * File:   Door.h
 * Author: fabienlenoir
 *
 * Created on September 18, 2009, 8:21 AM
 */

#ifndef _DOOR_H
#define	_DOOR_H
#include "Tile.h"

class Door : public Tile{
public:
    Door(const unsigned int posX=0, const unsigned int posY=0);
    Door(const Door& orig);
    virtual ~Door();

    virtual void paint(View *v) const;
    virtual void enter(Movable *m);
    virtual MapSite* clone(unsigned int x, unsigned int y) const;

    bool isOpen() const;
    bool isClosed() const;

    virtual void open();
    virtual void close();

protected:
    MS_TYPE getType() const;

    bool _open;

};

#endif	/* _DOOR_H */

